#define _CRT_SECURE_NO_WARNINGS 1

#include "stack.h"

void Test()
{
	ST s;

	STInit(&s);
	STPush(&s, 1);
	STPush(&s, 2);
	STPush(&s, 3);
	STPush(&s, 4);
	STPush(&s, 5);
	
	int retSize = STSize(&s);
	printf("%d\n", retSize);

	STDataType retTop = STTop(&s);
	printf("%d\n", retTop);

	while (s.top)
	{
		printf("%d ", s.a[s.top - 1]);
		STPop(&s);
	}

	STDestroy(&s);
}

int main()
{
	Test();
	return 0;
}